<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改商品信息')" />
    <th:block th:include="include :: bootstrap-fileinput-css"/>
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-shangpinxinxiTest-edit" th:object="${shangpinxinxi}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label">商品名称：</label>
                <div class="col-sm-8">
                    <input name="shangpinName" th:field="*{shangpinName}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">商品类别：</label>
                <div class="col-sm-8">
<!--                    <input name="shangpinLeibie"  class="form-control" type="text">-->
                    <select name="shangpinLeibie" class="form-control" th:field="*{shangpinLeibie}">
                        <option value="整套门">整套门</option>
                        <option value="防火门（门扇）">门扇</option>
                        <option value="防火门（门框）">门框</option>
                        <option value="双开防火门（左扇）">双开门左扇</option>
                        <option value="双开防火门（右扇）">双开门右扇</option>
                        <option value="防火锁">防火锁</option>
                        <option value="闭门器">闭门器</option>
                        <option value="拉爆盖">拉爆盖</option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">进货厂商：</label>
                <div class="col-sm-8">
                    <input name="jinhuoChangshang" th:field="*{jinhuoChangshang}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">规格宽：</label>
                <div class="col-sm-8">
                    <input name="GuiGeKuan" th:field="*{GuiGeKuan}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">规格高：</label>
                <div class="col-sm-8">
                    <input name="GuiGeGao" th:field="*{GuiGeGao}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">开向：</label>
                <div class="col-sm-8">
                    <input name="KaiXiang" th:field="*{KaiXiang}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">商品条码：</label>
                <div class="col-sm-8">
                    <img th:src="*{Tiaoma}">
                    <input name="Tiaoma" th:field="*{Tiaoma}" hidden>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">进货价：</label>
                <div class="col-sm-8">
                    <input name="jinhuoJia" th:field="*{jinhuoJia}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">商品售价：</label>
                <div class="col-sm-8">
                    <input name="shangpinShoujia" th:field="*{shangpinShoujia}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">备注：</label>
                <div class="col-sm-8">
                    <input name="beizhu" th:field="*{beizhu}" class="form-control" type="text">
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <th:block th:include="include :: bootstrap-fileinput-js"/>
    <script th:inline="javascript">
        var prefix = ctx + "shangpinxinxi/shangpinxinxiTest";
        $("#form-shangpinxinxiTest-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-shangpinxinxiTest-edit').serialize());
            }
        }
    </script>
</body>
</html>